﻿using System.ComponentModel.DataAnnotations;
using System.ComponentModel.DataAnnotations.Schema;

namespace XYAC.Framework.WohuaMesExtend.IHI.LocalData.Models
{

    [Table("LocalRecord")]
    public class LocalRecord
    {
        public LocalRecord()
        {
        }
        [Key]
        public string Guid { get; set; } = System.Guid.NewGuid().ToString();
        /// <summary>
        /// 条码
        /// </summary>
        public string? Sn { get; set; }
        /// <summary>
        /// 规格
        /// </summary>
        public string? SpecInfo { get; set; }
        /// <summary>
        /// 异常信息
        /// </summary>
        public string? LastSyncExceptionMsg { get; set; }
        /// <summary>
        /// 班次
        /// </summary>
        public string? ProductionShift { get; set; }
        /// <summary>
        /// 同步结果
        /// </summary>
        public bool? LastSyncResult { get; set; }
        /// <summary>
        /// 检测状态
        /// </summary>
        public int? CheckingState { get; set; }
        /// <summary>
        /// 检测状态描述
        /// </summary>
        public string? CheckingStateDesc { get; set; } = "检测完成";
        /// <summary>
        /// 最后同步日期时间
        /// </summary>
        public DateTime? LastSyncDate { get; set; }
        /// <summary>
        /// 数据Hash
        /// </summary>
        public string? SourceHash { get; set; }
        /// <summary>
        /// 原始数据ID主键
        /// </summary>
        public string? SourceKey { get; set; }
        /// <summary>
        /// 数据Json
        /// </summary>
        public string? SourceDataJson { get; set; }
        /// <summary>
        /// 表名
        /// </summary>
        public string? TableName { get; set; }
        /// <summary>
        /// 机器名称
        /// </summary>
        public string? MachineName { get; set; }
        /// <summary>
        /// 计划号
        /// </summary>
        public string? PlanId { get; set; }

    }
}
